RAIS  3.2
C:/Projekte/RAIS/FillCustomQueryTableCL/RANSP.cs
Go to the documentation of this file.
00001 using System;
00002 using System.Collections.Generic;
00003 using System.Linq;
00004 using System.Text;
00005 
00006 namespace FillCustomQueryTableCL
00007 {
00008     public class RANSP:Query
00009     {
00010         private static string QueryTypeName = "RAN Autogeneration";
00011         public RANSP(string name)
00012             : base(name, QueryTypeName)
00013         { 
00014             
00015         }
00016 
00017         protected override string GetQuery(string inputQueru)
00018         {
00019             string AS = "AS";
00020             int startIndex = inputQueru.IndexOf(AS, StringComparison.CurrentCultureIgnoreCase) + AS.Length;
00021 
00022             while (!((inputQueru[startIndex] == '\r' || inputQueru[startIndex] == ' ') &&
00023                     (inputQueru[startIndex - AS.Length - 1] == '\n' || inputQueru[startIndex - AS.Length - 1] == ' ')))
00024                 startIndex = inputQueru.IndexOf(AS, startIndex, StringComparison.CurrentCultureIgnoreCase) + AS.Length;
00025             return inputQueru.Substring(startIndex, inputQueru.Length - startIndex);
00026         }
00027     }
00028 }